import { Select } from "antd";
import { getZJFStorePage } from "./service";
const { Option } = Select;
const SupplierSelect = ({ value, onChange, options = [], placeholder, ...arg }) => {
	const onSearch = value => {
		// console.log("search:", value);
		// getData(value);
	};
	const getData = storeName => {
		getZJFStorePage({ storeName }).then(res => {
			console.log(res);
		});
	};
	return (
		<Select
			value={value}
			showSearch
			onChange={onChange}
			onSearch={onSearch}
			filterOption={(input, option) => (option?.label ?? "").toLowerCase().includes(input.toLowerCase())}
			options={options}
			placeholder={placeholder}
			{...arg}
		></Select>
	);
};
export default SupplierSelect;
